{extend name="base" /}
{block name="body"}
<div class="layui-body">
    <!--tab标签-->
    <div class="layui-tab layui-tab-brief">
        <ul class="layui-tab-title">
            <li class="layui-this">版本配置</li>
        </ul>
        <div class="layui-tab-content">
            <div class="layui-tab-item layui-show">
                <form class="layui-form form-container" action="{:url('admin/appversion/updateSiteVersion')}" method="post">
                    <div class="layui-form-item">
                        <label class="layui-form-label">版本号</label>
                        <div class="layui-input-block">
                            <input type="text" name="site_version[version_code]" value="{$site_version.version_code|default='1.0.0'}" required  lay-verify="required" placeholder="请输入版本号" autocomplete="off" class="layui-input">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">appid</label>
                        <div class="layui-input-block">
                            <input type="text" name="site_version[appid]" value="{$site_version.appid|default=''}" required  lay-verify="required" placeholder="请输入appid" autocomplete="off" class="layui-input">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">升级地址</label>
                        <div class="layui-input-block">
                            <input type="text" name="site_version[apk_url]" value="{$site_version.apk_url|default=''}" placeholder="请输入升级地址" autocomplete="off" class="layui-input">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">更新提示</label>
                        <div class="layui-input-block">
                            <textarea name="site_version[upgrade_point]" placeholder="请输入更新提示" class="layui-textarea">{$site_version.upgrade_point|default='有新版本需要更新'}</textarea>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">状态</label>
                        <div class="layui-input-block">
                            <input type="radio" name="site_version[status]" value="0" title="无更新" checked="checked">
                            <input type="radio" name="site_version[status]" value="1" title="更新">                            
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">发布时间</label>
                        <div class="layui-input-block">
                            <input type="text" name="site_version[update_time]" value="{:date('Y-m-d H:i:s')}" class="layui-input datetime">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-input-block">
                            <button class="layui-btn" lay-submit lay-filter="*">提交</button>
                            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
{/block}